
class ChatResultEntity {
  Metadata? metadata;
  Payload? payload;

  ChatResultEntity({this.metadata, this.payload});

  ChatResultEntity.fromJson(Map<String, dynamic> json) {
    metadata = json["metadata"] == null ? null : Metadata.fromJson(json["metadata"]);
    payload = json["payload"] == null ? null : Payload.fromJson(json["payload"]);
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> _data = <String, dynamic>{};
    if(metadata != null) {
      _data["metadata"] = metadata?.toJson();
    }
    if(payload != null) {
      _data["payload"] = payload?.toJson();
    }
    return _data;
  }
}

class Payload {
  int? status;
  String? text;
  String? message;
  String? audio;

  Payload({this.status, this.text, this.audio, this.message});

  Payload.fromJson(Map<String, dynamic> json) {
    status = json["status"];
    text = json["text"];
    audio = json["audio"];
    message = json["message"];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> _data = <String, dynamic>{};
    _data["status"] = status;
    _data["text"] = text;
    _data["audio"] = audio;
    _data["message"] = message;
    return _data;
  }
}

class Metadata {
  String? smid;
  String? version;
  String? responseStatus;
  String? responseType;

  Metadata({this.smid, this.version, this.responseStatus, this.responseType});

  Metadata.fromJson(Map<String, dynamic> json) {
    smid = json["smid"];
    version = json["version"];
    responseStatus = json["responseStatus"];
    responseType = json["responseType"];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> _data = <String, dynamic>{};
    _data["smid"] = smid;
    _data["version"] = version;
    _data["responseStatus"] = responseStatus;
    _data["responseType"] = responseType;
    return _data;
  }
}